# Smooth-scroll sample for the ColecoVision. Needs sjasmplus and python3 (standard library).
ROM     := scroll.rom
PY      ?= python3
OPENMSX ?= openmsx

all: $(ROM)

gfx.inc: gen_gfx.py
	$(PY) gen_gfx.py gfx.inc

$(ROM): scroll.asm gfx.inc
	sjasmplus --nologo --msg=war --fullpath -I. --sym=scroll.sym --lst=scroll.lst scroll.asm

# a window (never fullscreen)
run: $(ROM)
	$(OPENMSX) -machine ColecoVision -carta $(ROM) -command "set fullscreen off"

clean:
	rm -f $(ROM) gfx.inc scroll.sym scroll.lst

.PHONY: all run clean
